home *** CD-ROM | disk | FTP | other *** search
/ Aminet 45 / Aminet 45 (2001)(GTI - Schatztruhe)[!][Oct 2001].iso / Aminet / game / role / ldmud-3.2-bin.lha / mud / doc / driver / invocation < prev    next >
Text File  |  2001-06-30  |  10KB  |  257 lines

  1. NAME
  2.     driver/invocation
  3.  
  4. PURPOSE
  5.     Description of the invocation of the gamedriver, especially of the command
  6.     arguments. This document describes the commandline version of the driver
  7.     only; non-commandline versions are platform specific and described in
  8.     the related documentation.
  9.  
  10. DESCRIPTION
  11.     The driver is invoked from the commandline as other normal programs.
  12.     Neither the current directory nor the directory the executable is in need
  13.     to be in any special relation the directory of the mudlib. Once the driver
  14.     is running, it emits two streams of outputs:
  15.  
  16.       - driver-related messages on stderr; this unfortunately includes
  17.         LPC compiler diagnostics
  18.       - LPC runtime-related messages in the logfile <mudlib>/<host>.parse.log
  19.         (the name can be changed).
  20.  
  21.     It is possible to start the driver without any commandline arguments as
  22.     suitable defaults are specified at compile time. The invocation syntax
  23.     is:
  24.  
  25.         driver [options] [<portnumber>]...
  26.  
  27.     <portnumber> the number of the port the driver shall use to accept
  28.     connections. The maximum number of ports is determined by MAXNUMPORTS
  29.     in the source file config.h.
  30.  
  31.     The options modify the behaviour of the gamedriver. Some of them are only
  32.     available if a certain compile-time option was enabled (typically in
  33.     the source file config.h). The following options are recognized:
  34.  
  35.       -P|--inherit <fd-number>
  36.         Inherit filedescriptor <fd-number> from the parent process
  37.         as socket to listen for connections.
  38.         Only available if compiled with MAXNUMPORTS.
  39.  
  40.       -u|--udp <portnumber>
  41.         Specify the <portnumber> for the UDP port, overriding the compiled-in
  42.         default.
  43.         Only available if compiled with CATCH_UDP_PORT.
  44.  
  45.       -D|--define <macro>[=<text>]
  46.         Add <macro> (optionally to be expanded to <text>) to the list of
  47.         predefined macros known by the LPC compiler.
  48.  
  49.       -E|--eval-cost <ticks>
  50.         Set the number of <ticks> available for one evaluation thread.
  51.         If 0, execution is unlimited.
  52.  
  53.       -M|--master <filename>
  54.         Use <filename> for the master object.
  55.  
  56.       -m|--mudlib <pathname>
  57.         Use <pathname> as the top directory of the mudlib.
  58.  
  59.       --debug-file <filename>
  60.         Log all debug output in <filename> instead of <mudlib>/<host>.debug.log .
  61.  
  62.       --no-compat
  63.       --compat
  64.         Select the mode (plain or compat) of the driver.
  65.         This choice does not affect the default name of the master object.
  66.  
  67.       -d|--debug
  68.         Generate debug output; repeat the argument for even more output:
  69.           >= 1: log resets, clean ups, swaps, reception of urgend data,
  70.                    telnet negotiation states.
  71.                 check_a_lot_of_refcounts() on startup when swapping of
  72.                    variables is disabled.
  73.           >= 2: log all add_message()s, name lookup failures, new players.
  74.           >= 3: progress of garbage collection
  75.           >= 4: even more junk from garbage collection
  76.  
  77.       -c|--list-compiles
  78.         List the name of every compiled file on stderr.
  79.  
  80.       -e|--no-preload
  81.         Pass a non-zero argument (the number of occurences of this option)
  82.         to master->preload(), which usually inhibits all preloads of castles
  83.         and other objects.
  84.  
  85.       --erq <filename>
  86.         Use <filename> instead of 'erq' as the basename of the ERQ executable.
  87.         If the name starts with a '/', it is take to be an absolute pathname,
  88.         otherwise it is interpreted relative to <bindir>. If not specified,
  89.         'erq' is used as the executable name.
  90.  
  91.       -N|--no-erq
  92.         Don't start the erq demon (if it would be started at all).
  93.  
  94.       -t|--no-heart
  95.         Disable heartbeats and call_outs.
  96.  
  97.       -f|--funcall <word>
  98.         The lfun master->flag() is called with <word> as argument before the
  99.         gamedriver accepts netword connections.
  100.  
  101.       --max-array <size>
  102.         The maximum number of elements an array can hold.
  103.         Set to 0, arrays of any size are allowed.
  104.  
  105.       --max-mapping <size>
  106.         The maximum number of elements a mapping can hold.
  107.         Set to 0, mappings of any size are allowed.
  108.  
  109.       --max-callouts <size>
  110.         The maximum number of callouts at one time.
  111.         Set to 0, any number is allowed.
  112.  
  113.       --max-bytes <size>
  114.         The maximum number of bytes one read_bytes()/write_bytes() call
  115.         can handle.
  116.         Set to 0, arrays of any size are allowed.
  117.  
  118.       --max-file <size>
  119.         The maximum number of bytes one read_file()/write_file() call
  120.         can handle.
  121.         Set to 0, arrays of any size are allowed.
  122.  
  123.       --cleanup-time <time>
  124.         The idle time in seconds for an object before the driver tries to
  125.         clean it up. It should be substantially longer than the reset time.
  126.         A time <= 0 disables the cleanup mechanism.
  127.  
  128.       --reset-time <time>
  129.         The time in seconds before an object is reset. A time <= 0 disables
  130.         the reset mechanism.
  131.  
  132.       -s <time>  | --swap-time <time>
  133.       -s v<time> | --swap-variables <time>
  134.         Time in seconds before an object (or its variables) are swapped out.
  135.         A time less or equal 0 disables swapping.
  136.  
  137.       -s f<name> | --swap-file <name>
  138.         Swap into file <name> instead of <mudlib>/LP_SWAP.<host> .
  139.  
  140.       -s c       | --swap-compact
  141.         Reuse free space in the swap file immediately.
  142.         Giving this option results in smaller, but also more fragmented
  143.         swapfiles, and the swap performance may degrade.
  144.  
  145.       --max-malloc <size>
  146.         Restrict total memory allocations to <size> bytes.
  147.         A <size> of 0 or 'unlimited' removes any restriction.\n"
  148.  
  149.       --min-malloc <size>
  150.       --min-small-malloc <size>
  151.         Determine the sizes for the explicite initial large resp. small chunk
  152.         allocation. A size of 0 disables the explicite initial allocations.
  153.  
  154.       -r u<size> | --reserve-user <size>
  155.       -r m<size> | --reserve-master <size>
  156.       -r s<size> | --reserve-system <size>
  157.         Reserve <size> amount of memory for user/master/system allocations to
  158.         be held until main memory runs out.
  159.  
  160.       --strict-euids
  161.       --no-strict-euids
  162.         Enable/disable the enforced use of euids.
  163.  
  164.       --pidfile <filename>\n"
  165.         Write the pid of the driver process into <filename>.\n"
  166.  
  167.       --wizlist-file <filename>
  168.       --no-wizlist-file
  169.         Read and save the wizlist in the named file (always interpreted
  170.         relative the mudlib); resp. don't read or save the wizlist.
  171.  
  172.       --gcollect-outfd <filename>|<num>
  173.         Garbage collector output (like a log of all reclaimed memory blocks)
  174.         is sent to <filename> (or inherited fd <num>) instead of stderr.
  175.         Only available if compiled with MALLOC_smalloc.
  176.  
  177.       --y|--yydebug
  178.         Enable debugging of the LPC compiler.
  179.         Only available if compiled with YYDEBUG.
  180.  
  181.       --check-state <lvl>
  182.         Perform a regular simplistic check of the virtual machine according
  183.         to <lvl>:
  184.           = 0: no check
  185.           = 1: once per backend loop
  186.           = 2: at various points in the backend loop
  187.         Only available if compiled with DEBUG.
  188.  
  189.       --check-refcounts
  190.         Every backend cycle, all refcounts in the system are checked.
  191.         SLOW! Only available if compiled with DEBUG.
  192.  
  193.       --gobble-descriptors <num>
  194.         <num> (more) filedescriptors are used up. You'll know when you need it.
  195.         Only available if compiled with DEBUG.
  196.  
  197.       --check-strings
  198.         Every backend cycle, all shared strings in the system are checked.
  199.         SLOW! Only available if compiled with DEBUG and CHECK_STRINGS.
  200.  
  201.       -V|--version
  202.         Print the version of the driver and exit.
  203.  
  204.       --options
  205.         Print the version and compilation options of the driver and exit.
  206.  
  207.       -h|-?|--help
  208.         Display a command help and exit.
  209.  
  210.       --longhelp
  211.         Display a long command help and exit.
  212.  
  213.       --args <filename>
  214.         The driver reads and parses the given file and treats its contents
  215.         as if given on the commandline right where the --args option
  216.         occured. The file itself can again contain --args options.
  217.  
  218.  
  219. DESCRIPTION -- Argument Parser
  220.     The parser analyses the commandline arguments given with the driver
  221.     invocation and distinguishes 'options', which start with a '-', from
  222.     proper arguments. Options are further distinguished by their name and
  223.     may take an additional value. In general, options and arguments can be
  224.     givein in any order.
  225.  
  226.     Options are recognized in two forms. In the short form the option must
  227.     be given as a single '-' followed by a single letter. In the long form,
  228.     options start with '--' followed by a string of arbitrary length. The
  229.     short options are case sensitive, the long options aren't.
  230.     Most options can be specified in both the short and long form, but that
  231.     is not mandatory. Examples: '-r' and '--recursive'.
  232.  
  233.     If an option takes a value, it must follow the option immediately after
  234.     a separating space or '='. Additionally, the value for a short option
  235.     may follow the option without separator. Examples are: '-fMakefile',
  236.     '-f Makefile', '--file=Makefile' and '--file Makefile'.
  237.  
  238.     Short options may be collated into one argument, e.g. '-rtl', but
  239.     of these only the last may take a value.
  240.  
  241.     The option '--' marks the end of options. All following command arguments
  242.     are considered proper arguments even if they start with a '-' or '--'.
  243.  
  244.     The arguments are usually taken from the commandline; but the parser
  245.     is also able to read them from a textfiles, which can be nested. The
  246.     content of the textfiles is broken down into words delimited by whitespace,
  247.     which are then treated as given on the commandline at the place where
  248.     the instruction to read the textfile stood.
  249.  
  250.     The file parser recognizes simple double-quoted strings, which must be
  251.     contained on a single line. Additionally, the '#' character given by
  252.     itself is a comment marker - everthing after the '#' until the end
  253.     of the current line is ignored.
  254.  
  255. HISTORY
  256.     LDMud 3.2.9 added the --args option.
  257.